<?php

/**
 * Clientorder filter form base class.
 *
 * @package    briefingPropel
 * @subpackage filter
 * @author     Your name here
 */
abstract class BaseClientorderFormFilter extends BaseFormFilterPropel
{
  public function setup()
  {
    $this->setWidgets(array(
      'orderName'             => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'textCategoryId'        => new sfWidgetFormPropelChoice(array('model' => 'Textcategories', 'add_empty' => true)),
      'is_website'            => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'is_print'              => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'is_newsletter'         => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'is_poster'             => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'is_blog'               => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'otherTextMediumId'     => new sfWidgetFormPropelChoice(array('model' => 'Othertextmedium', 'add_empty' => true)),
      'targetGroupId'         => new sfWidgetFormPropelChoice(array('model' => 'Targetgroup', 'add_empty' => true)),
      'is_existing_custormer' => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'is_new_customer'       => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'is_women'              => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'is_men'                => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'formalStyleId'         => new sfWidgetFormPropelChoice(array('model' => 'Formalstyle', 'add_empty' => true)),
      'personStyleId'         => new sfWidgetFormPropelChoice(array('model' => 'Personstyle', 'add_empty' => true)),
      'emotionStyleId'        => new sfWidgetFormPropelChoice(array('model' => 'Emotionstyle', 'add_empty' => true)),
      'formulateId'           => new sfWidgetFormPropelChoice(array('model' => 'Formulatetext', 'add_empty' => true)),
      'freeTextId'            => new sfWidgetFormPropelChoice(array('model' => 'Freetext', 'add_empty' => true)),
      'urlImageStructure'     => new sfWidgetFormFilterInput(),
      'is_standard'           => new sfWidgetFormFilterInput(array('with_empty' => false)),
      'editionOptionsId'      => new sfWidgetFormPropelChoice(array('model' => 'Editionoptions', 'add_empty' => true)),
      'created_at'            => new sfWidgetFormFilterDate(array('from_date' => new sfWidgetFormDate(), 'to_date' => new sfWidgetFormDate())),
      'expires_at'            => new sfWidgetFormFilterDate(array('from_date' => new sfWidgetFormDate(), 'to_date' => new sfWidgetFormDate())),
      'updated_at'            => new sfWidgetFormFilterDate(array('from_date' => new sfWidgetFormDate(), 'to_date' => new sfWidgetFormDate())),
    ));

    $this->setValidators(array(
      'orderName'             => new sfValidatorPass(array('required' => false)),
      'textCategoryId'        => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Textcategories', 'column' => 'idTextCategories')),
      'is_website'            => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'is_print'              => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'is_newsletter'         => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'is_poster'             => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'is_blog'               => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'otherTextMediumId'     => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Othertextmedium', 'column' => 'idOtherTextMedium')),
      'targetGroupId'         => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Targetgroup', 'column' => 'idTargetGroup')),
      'is_existing_custormer' => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'is_new_customer'       => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'is_women'              => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'is_men'                => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'formalStyleId'         => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Formalstyle', 'column' => 'idFormalStyle')),
      'personStyleId'         => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Personstyle', 'column' => 'idPersonStyle')),
      'emotionStyleId'        => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Emotionstyle', 'column' => 'idEmotionStyle')),
      'formulateId'           => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Formulatetext', 'column' => 'idFormulateText')),
      'freeTextId'            => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Freetext', 'column' => 'idFreeText')),
      'urlImageStructure'     => new sfValidatorPass(array('required' => false)),
      'is_standard'           => new sfValidatorSchemaFilter('text', new sfValidatorInteger(array('required' => false))),
      'editionOptionsId'      => new sfValidatorPropelChoice(array('required' => false, 'model' => 'Editionoptions', 'column' => 'idEditionOptions')),
      'created_at'            => new sfValidatorDateRange(array('required' => false, 'from_date' => new sfValidatorDate(array('required' => false)), 'to_date' => new sfValidatorDate(array('required' => false)))),
      'expires_at'            => new sfValidatorDateRange(array('required' => false, 'from_date' => new sfValidatorDate(array('required' => false)), 'to_date' => new sfValidatorDate(array('required' => false)))),
      'updated_at'            => new sfValidatorDateRange(array('required' => false, 'from_date' => new sfValidatorDate(array('required' => false)), 'to_date' => new sfValidatorDate(array('required' => false)))),
    ));

    $this->widgetSchema->setNameFormat('clientorder_filters[%s]');

    $this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);

    parent::setup();
  }

  public function getModelName()
  {
    return 'Clientorder';
  }

  public function getFields()
  {
    return array(
      'idOrder'               => 'Number',
      'orderName'             => 'Text',
      'textCategoryId'        => 'ForeignKey',
      'is_website'            => 'Number',
      'is_print'              => 'Number',
      'is_newsletter'         => 'Number',
      'is_poster'             => 'Number',
      'is_blog'               => 'Number',
      'otherTextMediumId'     => 'ForeignKey',
      'targetGroupId'         => 'ForeignKey',
      'is_existing_custormer' => 'Number',
      'is_new_customer'       => 'Number',
      'is_women'              => 'Number',
      'is_men'                => 'Number',
      'formalStyleId'         => 'ForeignKey',
      'personStyleId'         => 'ForeignKey',
      'emotionStyleId'        => 'ForeignKey',
      'formulateId'           => 'ForeignKey',
      'freeTextId'            => 'ForeignKey',
      'urlImageStructure'     => 'Text',
      'is_standard'           => 'Number',
      'editionOptionsId'      => 'ForeignKey',
      'created_at'            => 'Date',
      'expires_at'            => 'Date',
      'updated_at'            => 'Date',
    );
  }
}
